package dao;

import Utils.db.dao.PageDao;
import pojo.Task;

import java.sql.SQLException;
import java.util.List;

public interface TaskDAO extends PageDao<Task> {
    public Integer addTask(Task task);

    public Integer deleteTaskById(Integer id);

    public Integer updateTaskById(Task task);

    public List<Task> queryAllTasks() throws SQLException;

    public List<Task> queryAllTasksByUserId(Integer userId) throws SQLException;

    public Task queryTaskById(Integer id) throws SQLException;

    public List<Task> queryTasksByTasknameBlur(String taskname) throws SQLException;

    public List<Task> queryBeanListPerPageTasknameBlur(Integer eStart, Integer ecp, String taskname) throws SQLException;

    public List<Task> queryBeanListPerPageTasknameBlurByUserId(Integer eStart, Integer ecp, String taskname, Integer userId) throws SQLException;

    public List<Task> queryBeanListPerPageByUserId(Integer eStart, Integer ecp, Integer userId) throws SQLException;

    public Integer getEctTasknameBlur(String taskname) throws SQLException;

    public Integer getEctTasknameBlurByUserId(String taskname, Integer userId) throws SQLException;

    public Integer getEctByUserId(Integer userId) throws SQLException;
}
